package com.futureCloudMOM.core.domain;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.futureCloudMOM.core.entity.FBaseEntity;
import com.futureCloudMOM.framework.dict.Dict;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.io.Serializable;
import java.math.BigDecimal;

@Data
@EqualsAndHashCode(callSuper = true)
@ApiModel(value = "Basic_Process", description = "工序表")
@TableName(value = "Basic_Process")
public class BasicProcess extends FBaseEntity implements Serializable {



    @NotBlank(message="[工序编码]不能为空")
    @Size(max= 500,message="编码长度不能超过500")
    @ApiModelProperty("工序编码")
    @Length(max= 500,message="编码长度不能超过500")
    @TableField(value = "code")
    private String code;

    @NotBlank(message="[工序名称]不能为空")
    @Size(max= 500,message="编码长度不能超过500")
    @ApiModelProperty("工序名称")
    @Length(max= 500,message="编码长度不能超过500")
    @TableField(value = "name")
    private String name;

    @Size(max= 500,message="编码长度不能超过500")
    @ApiModelProperty("备注")
    @Length(max= 500,message="编码长度不能超过500")
    @TableField(value = "remark")
    private String remark;

    @NotNull(message="[状态]不能为空")
    @ApiModelProperty("状态")
    @TableField(value = "status")
    @Dict(dictCode = "sys_normal_disable")
    private Long status;

    @ApiModelProperty("工序类别")
    @TableField(value = "classId")
    private Long classId;

    @Size(max= 500,message="编码长度不能超过500")
    @ApiModelProperty("标准工时")
    @Length(max= 500,message="编码长度不能超过500")
    @TableField(value = "stdTime")
    private String stdTime;

    @Size(max= 500,message="编码长度不能超过500")
    @ApiModelProperty("工价")
    @Length(max= 500,message="编码长度不能超过500")
    @TableField(value = "priceOne")
    private BigDecimal priceOne;

    @ApiModelProperty("是否需要模具/工装")
    @TableField(value = "moldFlag")
    @Dict(dictCode = "sys_yes_no")
    private Long moldFlag;

    @Size(max= 500,message="编码长度不能超过500")
    @ApiModelProperty("工序指导文件")
    @Length(max= 500,message="编码长度不能超过500")
    @TableField(value = "filesId")
    private String filesId;






}

